using System;
using System.Collections;
using LocalBoard.Domain;

namespace LocalBoard.Persistence
{
	/// <summary>
	/// Accessor for roles in the club
	/// </summary>
	public interface IClubRoleAccessor
	{
		/// <summary>
		/// Add club role to club member's profile
		/// </summary>
		/// <param name="roleId">club role id</param>
		/// <param name="profileId">club memeber's profile id</param>
		/// <param name="clubId">club id</param>
		void AddClubRoleToProfile(int roleId, int profileId, int clubId);
		/// <summary>
		/// Delete club role
		/// </summary>
		/// <param name="id">club role id</param>
		/// <param name="clubId">club id</param>
		void Delete(int id, int clubId);
		/// <summary>
		/// Delete club role from club memeber's profile
		/// </summary>
		/// <param name="roleId">club role id</param>
		/// <param name="profileId">club memeber's profile id</param>
		/// <param name="clubId">club id</param>
		void DeleteClubRoleFromProfile(int roleId, int profileId, int clubId);
		/// <summary>
		/// Get club role by role id
		/// </summary>
		/// <param name="id">club role id</param>
		/// <param name="clubId">club id</param>
		/// <returns></returns>
		UserRole Get(int id, int clubId);
		/// <summary>
		/// Get club role by role name
		/// </summary>
		/// <param name="roleName">club role name</param>
		/// <param name="clubId">club id</param>
		/// <returns></returns>
		UserRole Get(string roleName, int clubId);
		/// <summary>
		/// Get all club roles
		/// </summary>
		/// <param name="clubId">club id</param>
		/// <returns>all roles in club as Hashtable</returns>
		Hashtable GetAllClubRoles(int clubId);
		/// <summary>
		/// Get all the roles that club member has
		/// </summary>
		/// <param name="profileId">memeber's profile id</param>
		/// <param name="clubId">club id</param>
		/// <returns>all the roles as ArrayList</returns>
		ArrayList GetClubRolesByProfileId(int profileId, int clubId);
		/// <summary>
		/// Insert club role
		/// </summary>
		/// <param name="userRoleName">club role name</param>
		/// <param name="clubId">club id</param>
		/// <returns>inserted role's id</returns>
		int Insert(string userRoleName, int clubId);
		/// <summary>
		/// Update club role
		/// </summary>
		/// <param name="userRole">role that has information to update</param>
		/// <param name="clubId">club id</param>
		void Update(UserRole userRole, int clubId);
	}
}
